package com.sgcc.lms.config;

import com.sgcc.lms.bean.Cat;
import com.sgcc.lms.bean.Dog;
import com.sgcc.lms.bean.MyBeanPostProcessor;
import com.sgcc.lms.bean.User;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;

/**
 * @Author: 李孟帅
 * @CreateTime: 2020-11-27 17:22
 * @Description:
 */
@Configuration
@ComponentScan("com.sgcc.lms.bean")
public class ConfigOfLifeCycle {

    @Bean(initMethod="init",destroyMethod="detory")
    public Cat cat(){
        return new Cat();
    }

    @Bean
    public Dog dog2(){
        return new Dog("www");
    }

}
